{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "d99f3cb3",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "id": "64be87f3",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>ma5</th>\n",
       "      <th>ma10</th>\n",
       "      <th>ma20</th>\n",
       "      <th>v_ma5</th>\n",
       "      <th>v_ma10</th>\n",
       "      <th>v_ma20</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>23.53</td>\n",
       "      <td>25.88</td>\n",
       "      <td>24.16</td>\n",
       "      <td>23.53</td>\n",
       "      <td>95578.03</td>\n",
       "      <td>0.63</td>\n",
       "      <td>2.68</td>\n",
       "      <td>22.942</td>\n",
       "      <td>22.142</td>\n",
       "      <td>22.875</td>\n",
       "      <td>53782.64</td>\n",
       "      <td>46738.65</td>\n",
       "      <td>55576.11</td>\n",
       "      <td>2.39</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>22.80</td>\n",
       "      <td>23.78</td>\n",
       "      <td>23.53</td>\n",
       "      <td>22.80</td>\n",
       "      <td>60985.11</td>\n",
       "      <td>0.69</td>\n",
       "      <td>3.02</td>\n",
       "      <td>22.406</td>\n",
       "      <td>21.955</td>\n",
       "      <td>22.942</td>\n",
       "      <td>40827.52</td>\n",
       "      <td>42736.34</td>\n",
       "      <td>56007.50</td>\n",
       "      <td>1.53</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>22.88</td>\n",
       "      <td>23.37</td>\n",
       "      <td>22.82</td>\n",
       "      <td>22.71</td>\n",
       "      <td>52914.01</td>\n",
       "      <td>0.54</td>\n",
       "      <td>2.42</td>\n",
       "      <td>21.938</td>\n",
       "      <td>21.929</td>\n",
       "      <td>23.022</td>\n",
       "      <td>35119.58</td>\n",
       "      <td>41871.97</td>\n",
       "      <td>56372.85</td>\n",
       "      <td>1.32</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>22.25</td>\n",
       "      <td>22.76</td>\n",
       "      <td>22.28</td>\n",
       "      <td>22.02</td>\n",
       "      <td>36105.01</td>\n",
       "      <td>0.36</td>\n",
       "      <td>1.64</td>\n",
       "      <td>21.446</td>\n",
       "      <td>21.909</td>\n",
       "      <td>23.137</td>\n",
       "      <td>35397.58</td>\n",
       "      <td>39904.78</td>\n",
       "      <td>60149.60</td>\n",
       "      <td>0.90</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-14</th>\n",
       "      <td>21.49</td>\n",
       "      <td>21.99</td>\n",
       "      <td>21.92</td>\n",
       "      <td>21.48</td>\n",
       "      <td>23331.04</td>\n",
       "      <td>0.44</td>\n",
       "      <td>2.05</td>\n",
       "      <td>21.366</td>\n",
       "      <td>21.923</td>\n",
       "      <td>23.253</td>\n",
       "      <td>33590.21</td>\n",
       "      <td>42935.74</td>\n",
       "      <td>61716.11</td>\n",
       "      <td>0.58</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close    low    volume  price_change  p_change  \\\n",
       "2018-02-27  23.53  25.88  24.16  23.53  95578.03          0.63      2.68   \n",
       "2018-02-26  22.80  23.78  23.53  22.80  60985.11          0.69      3.02   \n",
       "2018-02-23  22.88  23.37  22.82  22.71  52914.01          0.54      2.42   \n",
       "2018-02-22  22.25  22.76  22.28  22.02  36105.01          0.36      1.64   \n",
       "2018-02-14  21.49  21.99  21.92  21.48  23331.04          0.44      2.05   \n",
       "\n",
       "               ma5    ma10    ma20     v_ma5    v_ma10    v_ma20  turnover  \n",
       "2018-02-27  22.942  22.142  22.875  53782.64  46738.65  55576.11      2.39  \n",
       "2018-02-26  22.406  21.955  22.942  40827.52  42736.34  56007.50      1.53  \n",
       "2018-02-23  21.938  21.929  23.022  35119.58  41871.97  56372.85      1.32  \n",
       "2018-02-22  21.446  21.909  23.137  35397.58  39904.78  60149.60      0.90  \n",
       "2018-02-14  21.366  21.923  23.253  33590.21  42935.74  61716.11      0.58  "
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#数据读取\n",
    "data = pd.read_csv(\"./data/stock_day.csv\")\n",
    "data = data.sort_index(ascending=False)\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "91890039",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>23.53</td>\n",
       "      <td>25.88</td>\n",
       "      <td>24.16</td>\n",
       "      <td>23.53</td>\n",
       "      <td>95578.03</td>\n",
       "      <td>0.63</td>\n",
       "      <td>2.68</td>\n",
       "      <td>2.39</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>22.80</td>\n",
       "      <td>23.78</td>\n",
       "      <td>23.53</td>\n",
       "      <td>22.80</td>\n",
       "      <td>60985.11</td>\n",
       "      <td>0.69</td>\n",
       "      <td>3.02</td>\n",
       "      <td>1.53</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>22.88</td>\n",
       "      <td>23.37</td>\n",
       "      <td>22.82</td>\n",
       "      <td>22.71</td>\n",
       "      <td>52914.01</td>\n",
       "      <td>0.54</td>\n",
       "      <td>2.42</td>\n",
       "      <td>1.32</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>22.25</td>\n",
       "      <td>22.76</td>\n",
       "      <td>22.28</td>\n",
       "      <td>22.02</td>\n",
       "      <td>36105.01</td>\n",
       "      <td>0.36</td>\n",
       "      <td>1.64</td>\n",
       "      <td>0.90</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-14</th>\n",
       "      <td>21.49</td>\n",
       "      <td>21.99</td>\n",
       "      <td>21.92</td>\n",
       "      <td>21.48</td>\n",
       "      <td>23331.04</td>\n",
       "      <td>0.44</td>\n",
       "      <td>2.05</td>\n",
       "      <td>0.58</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-13</th>\n",
       "      <td>21.40</td>\n",
       "      <td>21.90</td>\n",
       "      <td>21.48</td>\n",
       "      <td>21.31</td>\n",
       "      <td>30802.45</td>\n",
       "      <td>0.28</td>\n",
       "      <td>1.32</td>\n",
       "      <td>0.77</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-12</th>\n",
       "      <td>20.70</td>\n",
       "      <td>21.40</td>\n",
       "      <td>21.19</td>\n",
       "      <td>20.63</td>\n",
       "      <td>32445.39</td>\n",
       "      <td>0.82</td>\n",
       "      <td>4.03</td>\n",
       "      <td>0.81</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-09</th>\n",
       "      <td>21.20</td>\n",
       "      <td>21.46</td>\n",
       "      <td>20.36</td>\n",
       "      <td>20.19</td>\n",
       "      <td>54304.01</td>\n",
       "      <td>-1.50</td>\n",
       "      <td>-6.86</td>\n",
       "      <td>1.36</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-08</th>\n",
       "      <td>21.79</td>\n",
       "      <td>22.09</td>\n",
       "      <td>21.88</td>\n",
       "      <td>21.75</td>\n",
       "      <td>27068.16</td>\n",
       "      <td>0.09</td>\n",
       "      <td>0.41</td>\n",
       "      <td>0.68</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-07</th>\n",
       "      <td>22.69</td>\n",
       "      <td>23.11</td>\n",
       "      <td>21.80</td>\n",
       "      <td>21.29</td>\n",
       "      <td>53853.25</td>\n",
       "      <td>-0.50</td>\n",
       "      <td>-2.24</td>\n",
       "      <td>1.35</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close    low    volume  price_change  p_change  \\\n",
       "2018-02-27  23.53  25.88  24.16  23.53  95578.03          0.63      2.68   \n",
       "2018-02-26  22.80  23.78  23.53  22.80  60985.11          0.69      3.02   \n",
       "2018-02-23  22.88  23.37  22.82  22.71  52914.01          0.54      2.42   \n",
       "2018-02-22  22.25  22.76  22.28  22.02  36105.01          0.36      1.64   \n",
       "2018-02-14  21.49  21.99  21.92  21.48  23331.04          0.44      2.05   \n",
       "2018-02-13  21.40  21.90  21.48  21.31  30802.45          0.28      1.32   \n",
       "2018-02-12  20.70  21.40  21.19  20.63  32445.39          0.82      4.03   \n",
       "2018-02-09  21.20  21.46  20.36  20.19  54304.01         -1.50     -6.86   \n",
       "2018-02-08  21.79  22.09  21.88  21.75  27068.16          0.09      0.41   \n",
       "2018-02-07  22.69  23.11  21.80  21.29  53853.25         -0.50     -2.24   \n",
       "\n",
       "            turnover  \n",
       "2018-02-27      2.39  \n",
       "2018-02-26      1.53  \n",
       "2018-02-23      1.32  \n",
       "2018-02-22      0.90  \n",
       "2018-02-14      0.58  \n",
       "2018-02-13      0.77  \n",
       "2018-02-12      0.81  \n",
       "2018-02-09      1.36  \n",
       "2018-02-08      0.68  \n",
       "2018-02-07      1.35  "
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data = data.drop([\"ma5\",\"ma10\",\"ma20\",\"v_ma5\",\"v_ma10\",\"v_ma20\"],axis=1)\n",
    "data.head(10)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "c9131297",
   "metadata": {},
   "source": [
    "# 索引\n",
    "## 直接索引－－先列后行"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "id": "a5dfa940",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "23.53"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data[\"open\"][\"2018-02-27\"]\n",
    "\n",
    "# data[\"open\":\"volume\"][\"2018-02-27\"]   会报错，部支持范围内数据"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "17bd04c7",
   "metadata": {},
   "source": [
    "## loc,iloc索引－－先行后列"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "id": "09b8bfeb",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>23.53</td>\n",
       "      <td>25.88</td>\n",
       "      <td>24.16</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>22.80</td>\n",
       "      <td>23.78</td>\n",
       "      <td>23.53</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>22.88</td>\n",
       "      <td>23.37</td>\n",
       "      <td>22.82</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>22.25</td>\n",
       "      <td>22.76</td>\n",
       "      <td>22.28</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-14</th>\n",
       "      <td>21.49</td>\n",
       "      <td>21.99</td>\n",
       "      <td>21.92</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close\n",
       "2018-02-27  23.53  25.88  24.16\n",
       "2018-02-26  22.80  23.78  23.53\n",
       "2018-02-23  22.88  23.37  22.82\n",
       "2018-02-22  22.25  22.76  22.28\n",
       "2018-02-14  21.49  21.99  21.92"
      ]
     },
     "execution_count": 38,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#loc[行，列]　　　通过名称来获取\n",
    "data.loc[\"2018-02-27\",\"open\"]  \n",
    "data.loc[\"2018-02-27\":\"2018-02-22\",\"open\"]\n",
    "\n",
    "#iloc[行下标，列下标]     通过下标来取值\n",
    "data.iloc[:5,:3]  "
   ]
  },
  {
   "cell_type": "markdown",
   "id": "ac9a11c0",
   "metadata": {},
   "source": [
    "## ix索引"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "id": "c03bd24c",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>23.53</td>\n",
       "      <td>25.88</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>22.80</td>\n",
       "      <td>23.78</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>22.88</td>\n",
       "      <td>23.37</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>22.25</td>\n",
       "      <td>22.76</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high\n",
       "2018-02-27  23.53  25.88\n",
       "2018-02-26  22.80  23.78\n",
       "2018-02-23  22.88  23.37\n",
       "2018-02-22  22.25  22.76"
      ]
     },
     "execution_count": 47,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# ix使用下标和名称组合作为索引\n",
    "# data.ix[0:4,[\"open\",\"high\"]]\n",
    "\n",
    "# ix将被淘汰，现在多和loc[行下标,列名称组合]  和iloc[行下标,列下表组合]混合使用\n",
    "# loc[data.index[行下表范围],[列名称组合]\n",
    "data.loc[data.index[0:4],[\"open\",\"high\"]]\n",
    "\n",
    "# iloc[行下标范围,data.columns.get_indexer([列名称组合])]\n",
    "data.iloc[0:4,data.columns.get_indexer([\"open\",\"high\"])]"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "1b6bd78e",
   "metadata": {},
   "source": [
    "# 赋值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 66,
   "id": "24e26c13",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/python/.local/lib/python3.7/site-packages/ipykernel_launcher.py:3: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame\n",
      "\n",
      "See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  This is separate from the ipykernel package so we can avoid doing imports until\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "2018-02-27    100\n",
       "2018-02-26      1\n",
       "2018-02-23      1\n",
       "2018-02-22      1\n",
       "2018-02-14      1\n",
       "             ... \n",
       "2015-03-06      1\n",
       "2015-03-05      1\n",
       "2015-03-04      1\n",
       "2015-03-03      1\n",
       "2015-03-02      1\n",
       "Name: close, Length: 643, dtype: int64"
      ]
     },
     "execution_count": 66,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data2 = data\n",
    "# 整列进行赋值\n",
    "data2[\"close\"] = 1\n",
    "# 某个值进行赋值\n",
    "data2[\"close\"][\"2018-02-27\"]=100\n",
    "data2[\"close\"]"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "3552d21b",
   "metadata": {},
   "source": [
    "# 排序(值排序+下标排序)\n",
    "## 对DataFrame进行排序"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 60,
   "id": "e30508e6",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>ma5</th>\n",
       "      <th>ma10</th>\n",
       "      <th>ma20</th>\n",
       "      <th>v_ma5</th>\n",
       "      <th>v_ma10</th>\n",
       "      <th>v_ma20</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2015-03-02</th>\n",
       "      <td>12.25</td>\n",
       "      <td>12.67</td>\n",
       "      <td>1</td>\n",
       "      <td>12.20</td>\n",
       "      <td>96291.73</td>\n",
       "      <td>0.32</td>\n",
       "      <td>2.62</td>\n",
       "      <td>12.520</td>\n",
       "      <td>12.520</td>\n",
       "      <td>12.520</td>\n",
       "      <td>96291.73</td>\n",
       "      <td>96291.73</td>\n",
       "      <td>96291.73</td>\n",
       "      <td>3.30</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-03</th>\n",
       "      <td>12.52</td>\n",
       "      <td>13.06</td>\n",
       "      <td>1</td>\n",
       "      <td>12.52</td>\n",
       "      <td>139071.61</td>\n",
       "      <td>0.18</td>\n",
       "      <td>1.44</td>\n",
       "      <td>12.610</td>\n",
       "      <td>12.610</td>\n",
       "      <td>12.610</td>\n",
       "      <td>117681.67</td>\n",
       "      <td>117681.67</td>\n",
       "      <td>117681.67</td>\n",
       "      <td>4.76</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-04</th>\n",
       "      <td>12.80</td>\n",
       "      <td>12.92</td>\n",
       "      <td>1</td>\n",
       "      <td>12.61</td>\n",
       "      <td>67075.44</td>\n",
       "      <td>0.20</td>\n",
       "      <td>1.57</td>\n",
       "      <td>12.707</td>\n",
       "      <td>12.707</td>\n",
       "      <td>12.707</td>\n",
       "      <td>100812.93</td>\n",
       "      <td>100812.93</td>\n",
       "      <td>100812.93</td>\n",
       "      <td>2.30</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-05</th>\n",
       "      <td>12.88</td>\n",
       "      <td>13.45</td>\n",
       "      <td>1</td>\n",
       "      <td>12.87</td>\n",
       "      <td>93180.39</td>\n",
       "      <td>0.26</td>\n",
       "      <td>2.02</td>\n",
       "      <td>12.820</td>\n",
       "      <td>12.820</td>\n",
       "      <td>12.820</td>\n",
       "      <td>98904.79</td>\n",
       "      <td>98904.79</td>\n",
       "      <td>98904.79</td>\n",
       "      <td>3.19</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-06</th>\n",
       "      <td>13.17</td>\n",
       "      <td>14.48</td>\n",
       "      <td>1</td>\n",
       "      <td>13.13</td>\n",
       "      <td>179831.72</td>\n",
       "      <td>1.12</td>\n",
       "      <td>8.51</td>\n",
       "      <td>13.112</td>\n",
       "      <td>13.112</td>\n",
       "      <td>13.112</td>\n",
       "      <td>115090.18</td>\n",
       "      <td>115090.18</td>\n",
       "      <td>115090.18</td>\n",
       "      <td>6.16</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-14</th>\n",
       "      <td>21.49</td>\n",
       "      <td>21.99</td>\n",
       "      <td>1</td>\n",
       "      <td>21.48</td>\n",
       "      <td>23331.04</td>\n",
       "      <td>0.44</td>\n",
       "      <td>2.05</td>\n",
       "      <td>21.366</td>\n",
       "      <td>21.923</td>\n",
       "      <td>23.253</td>\n",
       "      <td>33590.21</td>\n",
       "      <td>42935.74</td>\n",
       "      <td>61716.11</td>\n",
       "      <td>0.58</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>22.25</td>\n",
       "      <td>22.76</td>\n",
       "      <td>1</td>\n",
       "      <td>22.02</td>\n",
       "      <td>36105.01</td>\n",
       "      <td>0.36</td>\n",
       "      <td>1.64</td>\n",
       "      <td>21.446</td>\n",
       "      <td>21.909</td>\n",
       "      <td>23.137</td>\n",
       "      <td>35397.58</td>\n",
       "      <td>39904.78</td>\n",
       "      <td>60149.60</td>\n",
       "      <td>0.90</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>22.88</td>\n",
       "      <td>23.37</td>\n",
       "      <td>1</td>\n",
       "      <td>22.71</td>\n",
       "      <td>52914.01</td>\n",
       "      <td>0.54</td>\n",
       "      <td>2.42</td>\n",
       "      <td>21.938</td>\n",
       "      <td>21.929</td>\n",
       "      <td>23.022</td>\n",
       "      <td>35119.58</td>\n",
       "      <td>41871.97</td>\n",
       "      <td>56372.85</td>\n",
       "      <td>1.32</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>22.80</td>\n",
       "      <td>23.78</td>\n",
       "      <td>1</td>\n",
       "      <td>22.80</td>\n",
       "      <td>60985.11</td>\n",
       "      <td>0.69</td>\n",
       "      <td>3.02</td>\n",
       "      <td>22.406</td>\n",
       "      <td>21.955</td>\n",
       "      <td>22.942</td>\n",
       "      <td>40827.52</td>\n",
       "      <td>42736.34</td>\n",
       "      <td>56007.50</td>\n",
       "      <td>1.53</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>23.53</td>\n",
       "      <td>25.88</td>\n",
       "      <td>1</td>\n",
       "      <td>23.53</td>\n",
       "      <td>95578.03</td>\n",
       "      <td>0.63</td>\n",
       "      <td>2.68</td>\n",
       "      <td>22.942</td>\n",
       "      <td>22.142</td>\n",
       "      <td>22.875</td>\n",
       "      <td>53782.64</td>\n",
       "      <td>46738.65</td>\n",
       "      <td>55576.11</td>\n",
       "      <td>2.39</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>643 rows × 14 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close    low     volume  price_change  p_change  \\\n",
       "2015-03-02  12.25  12.67      1  12.20   96291.73          0.32      2.62   \n",
       "2015-03-03  12.52  13.06      1  12.52  139071.61          0.18      1.44   \n",
       "2015-03-04  12.80  12.92      1  12.61   67075.44          0.20      1.57   \n",
       "2015-03-05  12.88  13.45      1  12.87   93180.39          0.26      2.02   \n",
       "2015-03-06  13.17  14.48      1  13.13  179831.72          1.12      8.51   \n",
       "...           ...    ...    ...    ...        ...           ...       ...   \n",
       "2018-02-14  21.49  21.99      1  21.48   23331.04          0.44      2.05   \n",
       "2018-02-22  22.25  22.76      1  22.02   36105.01          0.36      1.64   \n",
       "2018-02-23  22.88  23.37      1  22.71   52914.01          0.54      2.42   \n",
       "2018-02-26  22.80  23.78      1  22.80   60985.11          0.69      3.02   \n",
       "2018-02-27  23.53  25.88      1  23.53   95578.03          0.63      2.68   \n",
       "\n",
       "               ma5    ma10    ma20      v_ma5     v_ma10     v_ma20  turnover  \n",
       "2015-03-02  12.520  12.520  12.520   96291.73   96291.73   96291.73      3.30  \n",
       "2015-03-03  12.610  12.610  12.610  117681.67  117681.67  117681.67      4.76  \n",
       "2015-03-04  12.707  12.707  12.707  100812.93  100812.93  100812.93      2.30  \n",
       "2015-03-05  12.820  12.820  12.820   98904.79   98904.79   98904.79      3.19  \n",
       "2015-03-06  13.112  13.112  13.112  115090.18  115090.18  115090.18      6.16  \n",
       "...            ...     ...     ...        ...        ...        ...       ...  \n",
       "2018-02-14  21.366  21.923  23.253   33590.21   42935.74   61716.11      0.58  \n",
       "2018-02-22  21.446  21.909  23.137   35397.58   39904.78   60149.60      0.90  \n",
       "2018-02-23  21.938  21.929  23.022   35119.58   41871.97   56372.85      1.32  \n",
       "2018-02-26  22.406  21.955  22.942   40827.52   42736.34   56007.50      1.53  \n",
       "2018-02-27  22.942  22.142  22.875   53782.64   46738.65   55576.11      2.39  \n",
       "\n",
       "[643 rows x 14 columns]"
      ]
     },
     "execution_count": 60,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#sort_vlues(by=排序对象,ascending=是否升序)\n",
    "data3 =data.sort_values(by=[\"open\"],ascending=True)\n",
    "data3 =data.sort_values(by=[\"open\",\"high\"],ascending=True)\n",
    "data3\n",
    "\n",
    "\n",
    "# sort_index()\n",
    "data3 = data.sort_index()\n",
    "data3"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "d0afe252",
   "metadata": {},
   "source": [
    "## Series排序"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "id": "1ce0059b",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2015-03-02    2.62\n",
       "2015-03-03    1.44\n",
       "2015-03-04    1.57\n",
       "2015-03-05    2.02\n",
       "2015-03-06    8.51\n",
       "              ... \n",
       "2018-02-14    2.05\n",
       "2018-02-22    1.64\n",
       "2018-02-23    2.42\n",
       "2018-02-26    3.02\n",
       "2018-02-27    2.68\n",
       "Name: p_change, Length: 643, dtype: float64"
      ]
     },
     "execution_count": 62,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# 根据值排序\n",
    "data3[\"p_change\"].sort_values(ascending=False).head()\n",
    "data3[\"p_change\"]\n",
    "\n",
    "\n",
    "# 根据下表排序\n",
    "data3[\"p_change\"].sort_index()\n",
    "data3[\"p_change\"]"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "090578f0",
   "metadata": {},
   "source": [
    "# 算数运算+逻辑运算+统计运算\n",
    "## 算数运算"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 67,
   "id": "ae6127d2",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2015-03-02    13.25\n",
       "2015-03-03    13.52\n",
       "2015-03-04    13.80\n",
       "2015-03-05    13.88\n",
       "2015-03-06    14.17\n",
       "              ...  \n",
       "2018-02-14    22.49\n",
       "2018-02-22    23.25\n",
       "2018-02-23    23.88\n",
       "2018-02-26    23.80\n",
       "2018-02-27    24.53\n",
       "Name: open, Length: 643, dtype: float64"
      ]
     },
     "execution_count": 67,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data3[\"open\"]\n",
    "data3[\"open\"].add(1)\n",
    "data3[\"open\"].sumb(1)\n",
    "data3[\"open\"].mul(1)\n",
    "data3[\"open\"].add(1)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "07494558",
   "metadata": {},
   "source": [
    "## 逻辑运算\n",
    "### 逻辑运算符号"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 75,
   "id": "63440617",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>ma5</th>\n",
       "      <th>ma10</th>\n",
       "      <th>ma20</th>\n",
       "      <th>v_ma5</th>\n",
       "      <th>v_ma10</th>\n",
       "      <th>v_ma20</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2015-04-15</th>\n",
       "      <td>23.45</td>\n",
       "      <td>25.56</td>\n",
       "      <td>1</td>\n",
       "      <td>23.40</td>\n",
       "      <td>250311.59</td>\n",
       "      <td>1.14</td>\n",
       "      <td>4.91</td>\n",
       "      <td>21.560</td>\n",
       "      <td>19.315</td>\n",
       "      <td>17.442</td>\n",
       "      <td>174581.78</td>\n",
       "      <td>138001.54</td>\n",
       "      <td>119340.61</td>\n",
       "      <td>8.57</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-05-19</th>\n",
       "      <td>23.68</td>\n",
       "      <td>23.69</td>\n",
       "      <td>1</td>\n",
       "      <td>22.47</td>\n",
       "      <td>82945.73</td>\n",
       "      <td>0.25</td>\n",
       "      <td>1.08</td>\n",
       "      <td>22.318</td>\n",
       "      <td>21.166</td>\n",
       "      <td>21.536</td>\n",
       "      <td>100396.01</td>\n",
       "      <td>90830.02</td>\n",
       "      <td>97087.92</td>\n",
       "      <td>2.84</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-06-30</th>\n",
       "      <td>23.82</td>\n",
       "      <td>25.13</td>\n",
       "      <td>1</td>\n",
       "      <td>21.44</td>\n",
       "      <td>174521.44</td>\n",
       "      <td>1.19</td>\n",
       "      <td>5.00</td>\n",
       "      <td>25.830</td>\n",
       "      <td>27.929</td>\n",
       "      <td>29.447</td>\n",
       "      <td>140738.14</td>\n",
       "      <td>119712.07</td>\n",
       "      <td>142160.16</td>\n",
       "      <td>5.97</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-07-23</th>\n",
       "      <td>23.20</td>\n",
       "      <td>24.26</td>\n",
       "      <td>1</td>\n",
       "      <td>23.00</td>\n",
       "      <td>141147.69</td>\n",
       "      <td>1.68</td>\n",
       "      <td>7.48</td>\n",
       "      <td>22.030</td>\n",
       "      <td>22.978</td>\n",
       "      <td>25.000</td>\n",
       "      <td>112668.13</td>\n",
       "      <td>138161.35</td>\n",
       "      <td>127490.18</td>\n",
       "      <td>4.83</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-10-26</th>\n",
       "      <td>23.32</td>\n",
       "      <td>23.46</td>\n",
       "      <td>1</td>\n",
       "      <td>21.06</td>\n",
       "      <td>178488.00</td>\n",
       "      <td>-0.58</td>\n",
       "      <td>-2.59</td>\n",
       "      <td>20.632</td>\n",
       "      <td>20.057</td>\n",
       "      <td>17.844</td>\n",
       "      <td>135255.37</td>\n",
       "      <td>136241.55</td>\n",
       "      <td>104451.05</td>\n",
       "      <td>6.11</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close    low     volume  price_change  p_change  \\\n",
       "2015-04-15  23.45  25.56      1  23.40  250311.59          1.14      4.91   \n",
       "2015-05-19  23.68  23.69      1  22.47   82945.73          0.25      1.08   \n",
       "2015-06-30  23.82  25.13      1  21.44  174521.44          1.19      5.00   \n",
       "2015-07-23  23.20  24.26      1  23.00  141147.69          1.68      7.48   \n",
       "2015-10-26  23.32  23.46      1  21.06  178488.00         -0.58     -2.59   \n",
       "\n",
       "               ma5    ma10    ma20      v_ma5     v_ma10     v_ma20  turnover  \n",
       "2015-04-15  21.560  19.315  17.442  174581.78  138001.54  119340.61      8.57  \n",
       "2015-05-19  22.318  21.166  21.536  100396.01   90830.02   97087.92      2.84  \n",
       "2015-06-30  25.830  27.929  29.447  140738.14  119712.07  142160.16      5.97  \n",
       "2015-07-23  22.030  22.978  25.000  112668.13  138161.35  127490.18      4.83  \n",
       "2015-10-26  20.632  20.057  17.844  135255.37  136241.55  104451.05      6.11  "
      ]
     },
     "execution_count": 75,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data3[\"open\"]>23 #返回布尔值,符合条件的为TRUE\n",
    "data3[data3[\"open\"]>23] #data3[Ture]  返回所有符合条件的数据\n",
    "data3[data3[\"open\"]>23][\"open\"]\n",
    "\n",
    "#多条件筛选 注:每个条件需要使用括号,避免歧义\n",
    "data3[(data3[\"open\"]>23) & (data3[\"open\"]<24)].head()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "3ac06e56",
   "metadata": {},
   "source": [
    "### 逻辑运算函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 79,
   "id": "5d04c3c5",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>ma5</th>\n",
       "      <th>ma10</th>\n",
       "      <th>ma20</th>\n",
       "      <th>v_ma5</th>\n",
       "      <th>v_ma10</th>\n",
       "      <th>v_ma20</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2015-11-26</th>\n",
       "      <td>23.85</td>\n",
       "      <td>24.08</td>\n",
       "      <td>1</td>\n",
       "      <td>23.50</td>\n",
       "      <td>51446.29</td>\n",
       "      <td>-0.31</td>\n",
       "      <td>-1.30</td>\n",
       "      <td>23.710</td>\n",
       "      <td>24.357</td>\n",
       "      <td>23.395</td>\n",
       "      <td>74550.04</td>\n",
       "      <td>110489.85</td>\n",
       "      <td>109815.49</td>\n",
       "      <td>1.76</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-01-31</th>\n",
       "      <td>23.85</td>\n",
       "      <td>23.98</td>\n",
       "      <td>1</td>\n",
       "      <td>23.31</td>\n",
       "      <td>49155.02</td>\n",
       "      <td>-0.11</td>\n",
       "      <td>-0.46</td>\n",
       "      <td>24.036</td>\n",
       "      <td>24.583</td>\n",
       "      <td>24.411</td>\n",
       "      <td>60348.94</td>\n",
       "      <td>80496.48</td>\n",
       "      <td>91666.75</td>\n",
       "      <td>1.23</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open   high  close    low    volume  price_change  p_change  \\\n",
       "2015-11-26  23.85  24.08      1  23.50  51446.29         -0.31     -1.30   \n",
       "2018-01-31  23.85  23.98      1  23.31  49155.02         -0.11     -0.46   \n",
       "\n",
       "               ma5    ma10    ma20     v_ma5     v_ma10     v_ma20  turnover  \n",
       "2015-11-26  23.710  24.357  23.395  74550.04  110489.85  109815.49      1.76  \n",
       "2018-01-31  24.036  24.583  24.411  60348.94   80496.48   91666.75      1.23  "
      ]
     },
     "execution_count": 79,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#1.query(字符串即列名称逻辑条件)\n",
    "data3.query(\"open>23 & open<24\").head()\n",
    "\n",
    "#2.isin(列表)   是否在列表的元素中\n",
    "data3[\"open\"].isin([23.58,23.85])  #返回布尔值\n",
    "#返回open在23.58或23.85中的所有数据\n",
    "data3[data3[\"open\"].isin([23.58,23.85])]   "
   ]
  },
  {
   "cell_type": "markdown",
   "id": "96489921",
   "metadata": {},
   "source": [
    "## 统计运算\n",
    "### describe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 81,
   "id": "f5e071cc",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>high</th>\n",
       "      <th>close</th>\n",
       "      <th>low</th>\n",
       "      <th>volume</th>\n",
       "      <th>price_change</th>\n",
       "      <th>p_change</th>\n",
       "      <th>ma5</th>\n",
       "      <th>ma10</th>\n",
       "      <th>ma20</th>\n",
       "      <th>v_ma5</th>\n",
       "      <th>v_ma10</th>\n",
       "      <th>v_ma20</th>\n",
       "      <th>turnover</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.0</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "      <td>643.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>21.272706</td>\n",
       "      <td>21.900513</td>\n",
       "      <td>1.0</td>\n",
       "      <td>20.771835</td>\n",
       "      <td>99905.519114</td>\n",
       "      <td>0.018802</td>\n",
       "      <td>0.190280</td>\n",
       "      <td>21.302362</td>\n",
       "      <td>21.267656</td>\n",
       "      <td>21.200946</td>\n",
       "      <td>100008.642691</td>\n",
       "      <td>100287.542177</td>\n",
       "      <td>100797.518398</td>\n",
       "      <td>2.936190</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>3.930973</td>\n",
       "      <td>4.077578</td>\n",
       "      <td>0.0</td>\n",
       "      <td>3.791968</td>\n",
       "      <td>73879.119354</td>\n",
       "      <td>0.898476</td>\n",
       "      <td>4.079698</td>\n",
       "      <td>3.880640</td>\n",
       "      <td>3.813602</td>\n",
       "      <td>3.686186</td>\n",
       "      <td>62761.578326</td>\n",
       "      <td>56759.082060</td>\n",
       "      <td>50101.575639</td>\n",
       "      <td>2.079375</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>12.250000</td>\n",
       "      <td>12.670000</td>\n",
       "      <td>1.0</td>\n",
       "      <td>12.200000</td>\n",
       "      <td>1158.120000</td>\n",
       "      <td>-3.520000</td>\n",
       "      <td>-10.030000</td>\n",
       "      <td>12.520000</td>\n",
       "      <td>12.520000</td>\n",
       "      <td>12.520000</td>\n",
       "      <td>10804.740000</td>\n",
       "      <td>19130.510000</td>\n",
       "      <td>23311.000000</td>\n",
       "      <td>0.040000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>19.000000</td>\n",
       "      <td>19.500000</td>\n",
       "      <td>1.0</td>\n",
       "      <td>18.525000</td>\n",
       "      <td>48533.210000</td>\n",
       "      <td>-0.390000</td>\n",
       "      <td>-1.850000</td>\n",
       "      <td>18.990000</td>\n",
       "      <td>19.102000</td>\n",
       "      <td>19.275000</td>\n",
       "      <td>55794.985000</td>\n",
       "      <td>59861.955000</td>\n",
       "      <td>64103.675000</td>\n",
       "      <td>1.360000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>21.440000</td>\n",
       "      <td>21.970000</td>\n",
       "      <td>1.0</td>\n",
       "      <td>20.980000</td>\n",
       "      <td>83175.930000</td>\n",
       "      <td>0.050000</td>\n",
       "      <td>0.260000</td>\n",
       "      <td>21.504000</td>\n",
       "      <td>21.623000</td>\n",
       "      <td>21.530000</td>\n",
       "      <td>86133.330000</td>\n",
       "      <td>89234.970000</td>\n",
       "      <td>96291.730000</td>\n",
       "      <td>2.500000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>23.400000</td>\n",
       "      <td>24.065000</td>\n",
       "      <td>1.0</td>\n",
       "      <td>22.850000</td>\n",
       "      <td>127580.055000</td>\n",
       "      <td>0.455000</td>\n",
       "      <td>2.305000</td>\n",
       "      <td>23.318000</td>\n",
       "      <td>23.098500</td>\n",
       "      <td>23.136000</td>\n",
       "      <td>127655.655000</td>\n",
       "      <td>124693.255000</td>\n",
       "      <td>124001.015000</td>\n",
       "      <td>3.915000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>34.990000</td>\n",
       "      <td>36.350000</td>\n",
       "      <td>1.0</td>\n",
       "      <td>34.010000</td>\n",
       "      <td>501915.410000</td>\n",
       "      <td>3.030000</td>\n",
       "      <td>10.030000</td>\n",
       "      <td>33.696000</td>\n",
       "      <td>32.186000</td>\n",
       "      <td>29.998000</td>\n",
       "      <td>404443.540000</td>\n",
       "      <td>360028.160000</td>\n",
       "      <td>269280.790000</td>\n",
       "      <td>12.560000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             open        high  close         low         volume  price_change  \\\n",
       "count  643.000000  643.000000  643.0  643.000000     643.000000    643.000000   \n",
       "mean    21.272706   21.900513    1.0   20.771835   99905.519114      0.018802   \n",
       "std      3.930973    4.077578    0.0    3.791968   73879.119354      0.898476   \n",
       "min     12.250000   12.670000    1.0   12.200000    1158.120000     -3.520000   \n",
       "25%     19.000000   19.500000    1.0   18.525000   48533.210000     -0.390000   \n",
       "50%     21.440000   21.970000    1.0   20.980000   83175.930000      0.050000   \n",
       "75%     23.400000   24.065000    1.0   22.850000  127580.055000      0.455000   \n",
       "max     34.990000   36.350000    1.0   34.010000  501915.410000      3.030000   \n",
       "\n",
       "         p_change         ma5        ma10        ma20          v_ma5  \\\n",
       "count  643.000000  643.000000  643.000000  643.000000     643.000000   \n",
       "mean     0.190280   21.302362   21.267656   21.200946  100008.642691   \n",
       "std      4.079698    3.880640    3.813602    3.686186   62761.578326   \n",
       "min    -10.030000   12.520000   12.520000   12.520000   10804.740000   \n",
       "25%     -1.850000   18.990000   19.102000   19.275000   55794.985000   \n",
       "50%      0.260000   21.504000   21.623000   21.530000   86133.330000   \n",
       "75%      2.305000   23.318000   23.098500   23.136000  127655.655000   \n",
       "max     10.030000   33.696000   32.186000   29.998000  404443.540000   \n",
       "\n",
       "              v_ma10         v_ma20    turnover  \n",
       "count     643.000000     643.000000  643.000000  \n",
       "mean   100287.542177  100797.518398    2.936190  \n",
       "std     56759.082060   50101.575639    2.079375  \n",
       "min     19130.510000   23311.000000    0.040000  \n",
       "25%     59861.955000   64103.675000    1.360000  \n",
       "50%     89234.970000   96291.730000    2.500000  \n",
       "75%    124693.255000  124001.015000    3.915000  \n",
       "max    360028.160000  269280.790000   12.560000  "
      ]
     },
     "execution_count": 81,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data3.describe()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "38b4cbd5",
   "metadata": {},
   "source": [
    "### 统计函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 90,
   "id": "6308e8c5",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "open            2015-03-02\n",
       "high            2015-03-02\n",
       "close           2015-03-02\n",
       "low             2015-03-02\n",
       "volume          2016-07-06\n",
       "price_change    2015-06-15\n",
       "p_change        2015-09-01\n",
       "ma5             2015-03-02\n",
       "ma10            2015-03-02\n",
       "ma20            2015-03-02\n",
       "v_ma5           2017-02-03\n",
       "v_ma10          2017-02-03\n",
       "v_ma20          2017-05-23\n",
       "turnover        2016-07-06\n",
       "dtype: object"
      ]
     },
     "execution_count": 90,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data3.max(0) #0代表列\n",
    "data3.max(1) #1代表行\n",
    "data3.min(0)\n",
    "\n",
    "data3.std(0)\n",
    "data3.var(0)\n",
    "data3.median(0)\n",
    "\n",
    "data3.idxmax(0)\n",
    "data3.idxmin(0)\n",
    "# data3.max(0)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "e8d4500a",
   "metadata": {},
   "source": [
    "### 累计统计函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "id": "6b894b04",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAD6CAYAAABamQdMAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjQuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8rg+JYAAAACXBIWXMAAAsTAAALEwEAmpwYAABcq0lEQVR4nO2dd5xVxfXAv7O9s8DS29KRKkXsvWGJNfbYYn6WRI2axGCaxtiSGKPG2GJvGLtGLBRFUBAE6SAdcWm7sCy7bC/z+2PuvHffffe9fX3bfD+f/dw2996z99175syZM2eElBKDwWAwtC+SWloAg8FgMMQeo9wNBoOhHWKUu8FgMLRDjHI3GAyGdohR7gaDwdAOMcrdYDAY2iHNKnchxHNCiGIhxCrH/puEEN8JIVYLIf5m23+HEGKjEGKdEOLUeAhtMBgMhuCkhFDmBeAx4CW9QwhxPHA2ME5KWSuE6G7tHwlcDIwCegOzhBDDpJSNwW5QUFAgCwsLI/oHDAaDoaOyZMmSPVLKbm7HmlXuUsq5QohCx+4bgAeklLVWmWJr/9nA69b+LUKIjcBkYEGwexQWFrJ48eLmRDEYDAaDDSHE94GORepzHwYcLYRYKIT4QghxiLW/D/CDrVyRtc9NqGuFEIuFEItLSkoiFMNgMBgMbkSq3FOALsBhwG+AN4QQIpwLSCmfllJOklJO6tbNtVVhMBgMhgiJVLkXAe9IxS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SdQDfgNhedczFQEq7OCVH+oETw3nvKxRQZhcPe7Q/VwfES8LBj/9/x7VD9m+P4Xfj2XGcDubb1+cAUl/uloDoOB+LtnBllyTHEJtODwIMBZLZ3qH6MihZ4GNWjvwb1AiVUftvx64EXm3ne9v9zNbDEUcbZoRoT2W3lC/HvWPI8u2beF/sz9rw3KBdMtvXcn0Ep2WZlt/bNA4bbjv89nOcOdLeW6da7cEIz/8NWlG/d7b0P69nb9r8OXB3knrF+77djRabYfpPHCOOdj1b2UN95q8zPrPcyE4fOQbn0SlHfcMzlj/V7H+D4VbTCaJmjUM2fFXhDik5HdVTNRoWEzQK6WOV7oqytcpRvsghlLQ+yfvTlKIX1+yD3PB1lXW3S5VCtkq9QnYqrsKzwAOdPsspsQtX+Wv5aoM7av9KSLSHy247NIbhitf+fmy3ZV1nPfR3Kh1yJ6jyqjYPs01AtnXrr/Gus/RtRflX9DjwZ4HxdboMl+16r/BrreutRH+qWUGS3jh0MLLZ+w/ewQuBCfe6oCmWt9fxuCfK/32zdt8F6zm7v/TRrX0jvjXUs23oOnZr51mL13m93yF6L6rdYiXJLlSVC9lDfeatMg3XuMtu7o+XfBnxBmDonTPlj9d77lUMZC6WocMgiXCKJQvkz6QcMBoOhHWJGqBoMBkM7xCh3g8FgaIcY5W4wGAztEKPcDQaDoR1ilLvBYDC0Q4xyNxgMhnaIUe4Gg8HQDvl/ogQAcFUDpiUAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "# 先排序\n",
    "data =data.sort_index()\n",
    "data.head()\n",
    "\n",
    "# 对p_change累计求和\n",
    "stock_rise = data[\"p_change\"]\n",
    "stock_rise.cumsum()\n",
    "\n",
    "# 绘制图像\n",
    "# plot方法集成了之前的折线图等\n",
    "import matplotlib.pyplot as plt\n",
    "\n",
    "stock_rise.plot()\n",
    "stock_rise.cumsum().plot()\n",
    "\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "id": "0bd8e5f9",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2015-03-02      2.620000\n",
       "2015-03-03      3.772800\n",
       "2015-03-04      5.923296\n",
       "2015-03-05     11.965058\n",
       "2015-03-06    101.822643\n",
       "                 ...    \n",
       "2018-02-14     -0.000000\n",
       "2018-02-22     -0.000000\n",
       "2018-02-23     -0.000000\n",
       "2018-02-26     -0.000000\n",
       "2018-02-27     -0.000000\n",
       "Name: p_change, Length: 643, dtype: float64"
      ]
     },
     "execution_count": 24,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#其他累计函数\n",
    "# 累计最大值\n",
    "stock_rise.cummax()\n",
    "# 累计最小大值\n",
    "stock_rise.cummin()\n",
    "# 累计求积\n",
    "stock_rise.cumprod()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "902aade0",
   "metadata": {},
   "source": [
    "### apply自定义函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 101,
   "id": "68a664f4",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>open</th>\n",
       "      <th>close</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2015-03-02</th>\n",
       "      <td>11.25</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-03</th>\n",
       "      <td>11.52</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-04</th>\n",
       "      <td>11.80</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-05</th>\n",
       "      <td>11.88</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2015-03-06</th>\n",
       "      <td>12.17</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-14</th>\n",
       "      <td>20.49</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-22</th>\n",
       "      <td>21.25</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-23</th>\n",
       "      <td>21.88</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-26</th>\n",
       "      <td>21.80</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2018-02-27</th>\n",
       "      <td>22.53</td>\n",
       "      <td>99</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>643 rows × 2 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "             open  close\n",
       "2015-03-02  11.25      0\n",
       "2015-03-03  11.52      0\n",
       "2015-03-04  11.80      0\n",
       "2015-03-05  11.88      0\n",
       "2015-03-06  12.17      0\n",
       "...           ...    ...\n",
       "2018-02-14  20.49      0\n",
       "2018-02-22  21.25      0\n",
       "2018-02-23  21.88      0\n",
       "2018-02-26  21.80      0\n",
       "2018-02-27  22.53     99\n",
       "\n",
       "[643 rows x 2 columns]"
      ]
     },
     "execution_count": 101,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# data[[操作的列名称组合]].apply(func,axis=0)\n",
    "data[[\"open\",\"close\"]].apply(lambda x: x.max() - x.min(),axis=0)\n",
    "\n",
    "data[[\"open\",\"close\"]].apply(lambda x: x-1,axis=0)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "1538e192",
   "metadata": {},
   "source": [
    "# pandas绘图方式\n",
    "## pandas.DataFrame.plot"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "6177742d",
   "metadata": {},
   "outputs": [],
   "source": [
    "# DataFrame.plot(kind='line')\n",
    "# kind : str，需要绘制图形的种类:line,bar,barh,hist,scatter,pie\n",
    "#关于bar的解释　https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.plot.barh.html\n",
    "#更多资料　https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.plot.html"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "a6a74ff3",
   "metadata": {},
   "source": [
    "## pandas.Series.plot"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "ff9760b2",
   "metadata": {},
   "outputs": [],
   "source": [
    "#更多资料　https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Series.plot.html"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "182ab615",
   "metadata": {},
   "source": [
    "# 文件读写和储存"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "9a817ba6",
   "metadata": {},
   "source": [
    "我们的数据⼤部分存在于⽂件当中，所以pandas会⽀持复杂的IO操作，pandas的API⽀持众多的⽂件格式，如CSV、SQL、XLS、JSON、HDF5。"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "11cbad2b",
   "metadata": {},
   "source": [
    "## CSV"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 112,
   "id": "ba09e859",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>open</th>\n",
       "      <th>close</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2018-02-27</td>\n",
       "      <td>23.53</td>\n",
       "      <td>24.16</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2018-02-26</td>\n",
       "      <td>22.80</td>\n",
       "      <td>23.53</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2018-02-23</td>\n",
       "      <td>22.88</td>\n",
       "      <td>22.82</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>2018-02-22</td>\n",
       "      <td>22.25</td>\n",
       "      <td>22.28</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>2018-02-14</td>\n",
       "      <td>21.49</td>\n",
       "      <td>21.92</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   Unnamed: 0   open  close\n",
       "0  2018-02-27  23.53  24.16\n",
       "1  2018-02-26  22.80  23.53\n",
       "2  2018-02-23  22.88  22.82\n",
       "3  2018-02-22  22.25  22.28\n",
       "4  2018-02-14  21.49  21.92"
      ]
     },
     "execution_count": 112,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#读取：DataFrame.read_csv(filepath_or_buffer＝文件路径，sep=分隔符，默认＂,＂，　usecols＝指定读取的列名，列表格式)\n",
    "read_data = pd.read_csv(\"./data/stock_day.csv\" ,sep=\",\"  ,usecols=[\"open\",\"close\"])\n",
    "read_data.head()\n",
    "\n",
    "# 写入：DataFrame.to_csv(path_or_buf=\"文件路径\"\n",
    "#                     , sep='分隔符\n",
    "#                     , columns=指定保存列名，列表格式\n",
    "#                     , header=set否保存表头(True　or False)\n",
    "#                     , index=是否保存索引(True　or False)\n",
    "#                     , mode=\"w\"('w'：重写, 'a' 追加)\n",
    "\n",
    "# read_data前１０行数据写入\n",
    "read_data[:10].to_csv(\"./data/stockToCsv.csv\",sep=\",\" ,index=True ,header=True,mode=\"w\")\n",
    "a=pd.read_csv(\"./data/stockToCsv.csv\" ,sep=\",\" )\n",
    "a\n",
    "# read_data前５行数据追加　追加建议header=False\n",
    "read_data[:5].to_csv(\"./data/stockToCsv.csv\",sep=\",\" ,index=True ,header=False,mode=\"a\")\n",
    "a=pd.read_csv(\"./data/stockToCsv.csv\" ,sep=\",\" )\n",
    "a.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "5154aeb3",
   "metadata": {},
   "source": [
    "## hdf"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "3186921c",
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>000001.SZ</th>\n",
       "      <th>000002.SZ</th>\n",
       "      <th>000004.SZ</th>\n",
       "      <th>000005.SZ</th>\n",
       "      <th>000006.SZ</th>\n",
       "      <th>000007.SZ</th>\n",
       "      <th>000008.SZ</th>\n",
       "      <th>000009.SZ</th>\n",
       "      <th>000010.SZ</th>\n",
       "      <th>000011.SZ</th>\n",
       "      <th>...</th>\n",
       "      <th>001965.SZ</th>\n",
       "      <th>603283.SH</th>\n",
       "      <th>002920.SZ</th>\n",
       "      <th>002921.SZ</th>\n",
       "      <th>300684.SZ</th>\n",
       "      <th>002922.SZ</th>\n",
       "      <th>300735.SZ</th>\n",
       "      <th>603329.SH</th>\n",
       "      <th>603655.SH</th>\n",
       "      <th>603080.SH</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>16.30</td>\n",
       "      <td>17.71</td>\n",
       "      <td>4.58</td>\n",
       "      <td>2.88</td>\n",
       "      <td>14.60</td>\n",
       "      <td>2.62</td>\n",
       "      <td>4.96</td>\n",
       "      <td>4.66</td>\n",
       "      <td>5.37</td>\n",
       "      <td>6.02</td>\n",
       "      <td>...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>17.02</td>\n",
       "      <td>19.20</td>\n",
       "      <td>4.65</td>\n",
       "      <td>3.02</td>\n",
       "      <td>15.97</td>\n",
       "      <td>2.65</td>\n",
       "      <td>4.95</td>\n",
       "      <td>4.70</td>\n",
       "      <td>5.37</td>\n",
       "      <td>6.27</td>\n",
       "      <td>...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17.02</td>\n",
       "      <td>17.28</td>\n",
       "      <td>4.56</td>\n",
       "      <td>3.06</td>\n",
       "      <td>14.37</td>\n",
       "      <td>2.63</td>\n",
       "      <td>4.82</td>\n",
       "      <td>4.47</td>\n",
       "      <td>5.37</td>\n",
       "      <td>5.96</td>\n",
       "      <td>...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>16.18</td>\n",
       "      <td>16.97</td>\n",
       "      <td>4.49</td>\n",
       "      <td>2.95</td>\n",
       "      <td>13.10</td>\n",
       "      <td>2.73</td>\n",
       "      <td>4.89</td>\n",
       "      <td>4.33</td>\n",
       "      <td>5.37</td>\n",
       "      <td>5.77</td>\n",
       "      <td>...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>16.95</td>\n",
       "      <td>17.19</td>\n",
       "      <td>4.55</td>\n",
       "      <td>2.99</td>\n",
       "      <td>13.18</td>\n",
       "      <td>2.77</td>\n",
       "      <td>4.97</td>\n",
       "      <td>4.42</td>\n",
       "      <td>5.37</td>\n",
       "      <td>5.92</td>\n",
       "      <td>...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>5 rows × 3562 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "   000001.SZ  000002.SZ  000004.SZ  000005.SZ  000006.SZ  000007.SZ  \\\n",
       "0      16.30      17.71       4.58       2.88      14.60       2.62   \n",
       "1      17.02      19.20       4.65       3.02      15.97       2.65   \n",
       "2      17.02      17.28       4.56       3.06      14.37       2.63   \n",
       "3      16.18      16.97       4.49       2.95      13.10       2.73   \n",
       "4      16.95      17.19       4.55       2.99      13.18       2.77   \n",
       "\n",
       "   000008.SZ  000009.SZ  000010.SZ  000011.SZ  ...  001965.SZ  603283.SH  \\\n",
       "0       4.96       4.66       5.37       6.02  ...        NaN        NaN   \n",
       "1       4.95       4.70       5.37       6.27  ...        NaN        NaN   \n",
       "2       4.82       4.47       5.37       5.96  ...        NaN        NaN   \n",
       "3       4.89       4.33       5.37       5.77  ...        NaN        NaN   \n",
       "4       4.97       4.42       5.37       5.92  ...        NaN        NaN   \n",
       "\n",
       "   002920.SZ  002921.SZ  300684.SZ  002922.SZ  300735.SZ  603329.SH  \\\n",
       "0        NaN        NaN        NaN        NaN        NaN        NaN   \n",
       "1        NaN        NaN        NaN        NaN        NaN        NaN   \n",
       "2        NaN        NaN        NaN        NaN        NaN        NaN   \n",
       "3        NaN        NaN        NaN        NaN        NaN        NaN   \n",
       "4        NaN        NaN        NaN        NaN        NaN        NaN   \n",
       "\n",
       "   603655.SH  603080.SH  \n",
       "0        NaN        NaN  \n",
       "1        NaN        NaN  \n",
       "2        NaN        NaN  \n",
       "3        NaN        NaN  \n",
       "4        NaN        NaN  \n",
       "\n",
       "[5 rows x 3562 columns]"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#读取：DataFrame.read_hdf(filepath_or_buffer＝文件路径, key =＂关键值＂)\n",
    "test_hdf = pd.read_hdf(\"./data/day_close.h5\") #此处未指定ｋｅｙ值是因为文件内就一种数据，可省略\n",
    "test_hdf.head()\n",
    "\n",
    "# 写入：DataFrame.to_hdf(path_or_buf=\"文件路径\"　,key=关键值\n",
    "test_hdf[:5].to_hdf(\"./data/test.h5\",key = \"demo\")\n",
    "\n",
    "#查看写入内容\n",
    "test_hdf = pd.read_hdf(\"./data/test.h5\",key = \"demo\") #\n",
    "test_hdf.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "f3496c40",
   "metadata": {},
   "source": [
    "注意：优先选择使⽤HDF5⽂件存储\n",
    "HDF5在存储的时候⽀持压缩，使⽤的⽅式是blosc，这个是速度最快的也是\n",
    "pandas默认⽀持的\n",
    "使⽤压缩可以提磁盘利⽤率，节省空间\n",
    "HDF5还是跨平台的，可以轻松迁移到hadoop 上⾯"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "ed033f63",
   "metadata": {},
   "source": [
    "## json"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "id": "ba37452a",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>article_link</th>\n",
       "      <th>headline</th>\n",
       "      <th>is_sarcastic</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>https://www.huffingtonpost.com/entry/versace-b...</td>\n",
       "      <td>former versace store clerk sues over secret 'b...</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>https://www.huffingtonpost.com/entry/roseanne-...</td>\n",
       "      <td>the 'roseanne' revival catches up to our thorn...</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>https://local.theonion.com/mom-starting-to-fea...</td>\n",
       "      <td>mom starting to fear son's web series closest ...</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>https://politics.theonion.com/boehner-just-wan...</td>\n",
       "      <td>boehner just wants wife to listen, not come up...</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>https://www.huffingtonpost.com/entry/jk-rowlin...</td>\n",
       "      <td>j.k. rowling wishes snape happy birthday in th...</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                        article_link  \\\n",
       "0  https://www.huffingtonpost.com/entry/versace-b...   \n",
       "1  https://www.huffingtonpost.com/entry/roseanne-...   \n",
       "2  https://local.theonion.com/mom-starting-to-fea...   \n",
       "3  https://politics.theonion.com/boehner-just-wan...   \n",
       "4  https://www.huffingtonpost.com/entry/jk-rowlin...   \n",
       "\n",
       "                                            headline  is_sarcastic  \n",
       "0  former versace store clerk sues over secret 'b...             0  \n",
       "1  the 'roseanne' revival catches up to our thorn...             0  \n",
       "2  mom starting to fear son's web series closest ...             1  \n",
       "3  boehner just wants wife to listen, not come up...             1  \n",
       "4  j.k. rowling wishes snape happy birthday in th...             0  "
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#读取：pandas.read_json(path_or_buf=文件路径, orient=显示方式, typ='frame', lines=是否按行显示（(True　or False))\n",
    "# 参数：\n",
    "# orient : string,Indication of expected JSON string format.\n",
    "#        'split' : dict like {index -> [index], columns -> [columns], data -> [values]}\n",
    "#                  split 将索引总结到索引，列名到列名，数据到数据。将三部分都分开了\n",
    "#        'records' : list like [{column -> value}, ... , {column -> value}]\n",
    "#                  records 以 columns：values 的形式输出\n",
    "#        'index' : dict like {index -> {column -> value}}\n",
    "#                  index 以 index：{columns：values}... 的形式输出\n",
    "#       'columns' : dict like {column -> {index -> value}},默认该格式\n",
    "#                 colums 以 columns:{index:values} 的形式输出\n",
    "#       'values' : just the values array\n",
    "#                 values 直接输出值\n",
    "# lines : boolean, default False\n",
    "\n",
    "\n",
    "test_json = pd.read_json(\"./data/Sarcasm_Headlines_Dataset.json\",orient=\"columns\",lines=True) \n",
    "test_json.head()\n",
    "#报错参考 https://blog.csdn.net/Duke_LH/article/details/84674715\n",
    "\n",
    "\n",
    "\n",
    "# 写入：DataFrame.to_hdf(path_or_buf=\"文件路径\"　,orient=存储的json形式，lines=是否储存为行）\n",
    "# 参数：\n",
    "# 将Pandas 对象存储为json格式\n",
    "# path_or_buf=None：⽂件地址\n",
    "# orient:存储的json形式，{‘split’,’records’,’index’,’columns’,’values’}\n",
    "# lines:⼀个对象存储为⼀⾏\n",
    "test_json[:5].to_json(\"./data/test.json\",orient = \"records\",lines=True)\n",
    "\n",
    "# #查看写入内容\n",
    "test_json = pd.read_json(\"./data/test.json\",orient=\"columns\",lines=True) \n",
    "test_json.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "d636d05f",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.10"
  },
  "toc": {
   "base_numbering": 1,
   "nav_menu": {},
   "number_sections": true,
   "sideBar": true,
   "skip_h1_title": false,
   "title_cell": "Table of Contents",
   "title_sidebar": "Contents",
   "toc_cell": false,
   "toc_position": {},
   "toc_section_display": true,
   "toc_window_display": false
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
